/*
MySQL Backup
Database: bolg
Backup Time: 2024-03-27 17:19:22
*/

SET FOREIGN_KEY_CHECKS=0;
DROP TABLE IF EXISTS `bolg`.`bolg_article`;
DROP TABLE IF EXISTS `bolg`.`bolg_article_column`;
DROP TABLE IF EXISTS `bolg`.`bolg_article_content`;
DROP TABLE IF EXISTS `bolg`.`bolg_article_label`;
DROP TABLE IF EXISTS `bolg`.`bolg_config`;
DROP TABLE IF EXISTS `bolg`.`bolg_diary`;
DROP TABLE IF EXISTS `bolg`.`bolg_diary_content`;
DROP TABLE IF EXISTS `bolg`.`bolg_diary_label`;
DROP TABLE IF EXISTS `bolg`.`bolg_friend`;
DROP TABLE IF EXISTS `bolg`.`bolg_friend_group`;
DROP TABLE IF EXISTS `bolg`.`bolg_friend_message`;
DROP TABLE IF EXISTS `bolg`.`bolg_group`;
DROP TABLE IF EXISTS `bolg`.`bolg_group_message`;
DROP TABLE IF EXISTS `bolg`.`bolg_group_user`;
DROP TABLE IF EXISTS `bolg`.`bolg_label`;
DROP TABLE IF EXISTS `bolg`.`bolg_user`;
CREATE TABLE `bolg_article` (
  `id` int(11) NOT NULL AUTO_INCREMENT,
  `title` varchar(255) NOT NULL COMMENT '标题',
  `synopsis` varchar(255) DEFAULT NULL COMMENT '简介',
  `cover` varchar(255) DEFAULT NULL COMMENT '封面',
  `type` tinyint(2) NOT NULL COMMENT '1文章,2视频,3md',
  `link` varchar(255) DEFAULT NULL COMMENT '文件地址',
  `column_id` int(11) NOT NULL COMMENT '栏目id',
  `create_time` datetime NOT NULL COMMENT '创建时间',
  `update_time` datetime DEFAULT NULL COMMENT '修改时间',
  `is_top` tinyint(2) NOT NULL DEFAULT '0' COMMENT '是否置顶  0否 1是',
  `is_show` tinyint(2) NOT NULL DEFAULT '1' COMMENT '是否展示  0否 1是',
  `is_delete` tinyint(2) NOT NULL DEFAULT '0' COMMENT '是否删除  0否 1是',
  PRIMARY KEY (`id`) USING BTREE
) ENGINE=InnoDB AUTO_INCREMENT=11 DEFAULT CHARSET=utf8mb4 ROW_FORMAT=DYNAMIC COMMENT='文章表';
CREATE TABLE `bolg_article_column` (
  `id` int(11) NOT NULL AUTO_INCREMENT,
  `name` varchar(255) NOT NULL COMMENT '栏目名称',
  `is_show` tinyint(2) NOT NULL DEFAULT '1' COMMENT '是否展示 0否  1是',
  `is_delete` tinyint(2) NOT NULL DEFAULT '0' COMMENT '是否删除 0否  1是',
  PRIMARY KEY (`id`) USING BTREE
) ENGINE=InnoDB AUTO_INCREMENT=4 DEFAULT CHARSET=utf8mb4 ROW_FORMAT=DYNAMIC COMMENT='文章栏目表';
CREATE TABLE `bolg_article_content` (
  `id` int(11) NOT NULL AUTO_INCREMENT,
  `article_id` int(11) NOT NULL COMMENT '文章id',
  `content` longtext NOT NULL COMMENT '内容',
  PRIMARY KEY (`id`) USING BTREE
) ENGINE=InnoDB AUTO_INCREMENT=12 DEFAULT CHARSET=utf8mb4 ROW_FORMAT=DYNAMIC COMMENT='文章内容\r\n';
CREATE TABLE `bolg_article_label` (
  `id` int(11) NOT NULL AUTO_INCREMENT,
  `article_id` int(11) NOT NULL COMMENT '文章id',
  `label_id` int(11) NOT NULL COMMENT '标签id',
  PRIMARY KEY (`id`) USING BTREE,
  KEY `article` (`article_id`),
  KEY `label` (`label_id`),
  CONSTRAINT `article` FOREIGN KEY (`article_id`) REFERENCES `bolg_article` (`id`),
  CONSTRAINT `label` FOREIGN KEY (`label_id`) REFERENCES `bolg_label` (`id`)
) ENGINE=InnoDB AUTO_INCREMENT=12 DEFAULT CHARSET=utf8mb4 ROW_FORMAT=DYNAMIC COMMENT='文章标签表\r\n';
CREATE TABLE `bolg_config` (
  `id` int(11) NOT NULL AUTO_INCREMENT,
  `name` varchar(255) NOT NULL COMMENT '配置名称',
  `value` varchar(255) NOT NULL COMMENT '配置值',
  `type` int(10) NOT NULL COMMENT '1：网页端首页信息配置',
  PRIMARY KEY (`id`) USING BTREE
) ENGINE=InnoDB AUTO_INCREMENT=5 DEFAULT CHARSET=utf8mb4 ROW_FORMAT=DYNAMIC COMMENT='配置表';
CREATE TABLE `bolg_diary` (
  `id` int(11) NOT NULL AUTO_INCREMENT,
  `title` varchar(255) NOT NULL COMMENT '日记标题',
  `address` varchar(255) NOT NULL COMMENT '地点',
  `is_show` tinyint(2) NOT NULL COMMENT '是否显示0是 1否',
  `create_time` datetime NOT NULL COMMENT '创建时间',
  PRIMARY KEY (`id`) USING BTREE
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 ROW_FORMAT=DYNAMIC COMMENT='日记';
CREATE TABLE `bolg_diary_content` (
  `id` int(11) NOT NULL AUTO_INCREMENT,
  `dariy_id` int(11) NOT NULL COMMENT '日记id',
  `content` text NOT NULL COMMENT '内容',
  PRIMARY KEY (`id`) USING BTREE
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 ROW_FORMAT=DYNAMIC COMMENT='日记内容';
CREATE TABLE `bolg_diary_label` (
  `id` int(11) NOT NULL AUTO_INCREMENT,
  `diary_id` int(11) NOT NULL COMMENT '日记id',
  `label_id` int(11) NOT NULL COMMENT '标签id',
  PRIMARY KEY (`id`) USING BTREE
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 ROW_FORMAT=DYNAMIC COMMENT='日记标签';
CREATE TABLE `bolg_friend` (
  `id` int(11) NOT NULL AUTO_INCREMENT COMMENT 'id',
  `user_id` int(11) NOT NULL COMMENT '用户id',
  `friend_id` int(11) NOT NULL COMMENT '好友id',
  `remark` varchar(255) NOT NULL COMMENT '好友备注',
  `group_id` int(11) NOT NULL COMMENT '分组id',
  `type` tinyint(2) NOT NULL COMMENT '好友类型  0未添加  1已添加',
  PRIMARY KEY (`id`) USING BTREE
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 ROW_FORMAT=DYNAMIC COMMENT='好友表';
CREATE TABLE `bolg_friend_group` (
  `id` int(11) NOT NULL AUTO_INCREMENT COMMENT 'id',
  `group_name` varchar(255) NOT NULL COMMENT '分组名称',
  `user_id` int(11) NOT NULL COMMENT '用户id',
  PRIMARY KEY (`id`) USING BTREE
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 ROW_FORMAT=DYNAMIC COMMENT='好友分组表';
CREATE TABLE `bolg_friend_message` (
  `id` int(11) NOT NULL AUTO_INCREMENT,
  `message` varchar(512) NOT NULL COMMENT '发送消息',
  `send_user_id` int(11) NOT NULL COMMENT '发送user_id',
  `acc_user_id` int(11) NOT NULL COMMENT '接收user_id',
  `acc_status` tinyint(2) NOT NULL COMMENT '接受状态',
  `type` tinyint(2) NOT NULL COMMENT '消息类型 0普通消息 1图片 2音频 3视频',
  `create_time` datetime NOT NULL COMMENT '创建时间',
  PRIMARY KEY (`id`) USING BTREE
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 ROW_FORMAT=DYNAMIC COMMENT='用户消息表';
CREATE TABLE `bolg_group` (
  `id` int(11) NOT NULL AUTO_INCREMENT,
  `group_name` varchar(255) DEFAULT NULL COMMENT '组名称',
  `create_time` datetime NOT NULL COMMENT '创建时间',
  `create_user_id` int(11) NOT NULL COMMENT '创建用户群主',
  `icon` varchar(255) NOT NULL COMMENT '群图标',
  `intro` varchar(255) NOT NULL COMMENT '群简介',
  PRIMARY KEY (`id`) USING BTREE
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 ROW_FORMAT=DYNAMIC;
CREATE TABLE `bolg_group_message` (
  `id` int(11) NOT NULL AUTO_INCREMENT,
  `message` varchar(512) NOT NULL COMMENT '发送消息',
  `send_user_id` int(11) NOT NULL COMMENT '发送user_id',
  `group_id` int(11) NOT NULL COMMENT '群id',
  `type` tinyint(2) NOT NULL COMMENT '消息类型 0普通消息 1图片 2音频 3视频',
  `create_time` datetime NOT NULL COMMENT '创建时间',
  PRIMARY KEY (`id`) USING BTREE
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 ROW_FORMAT=DYNAMIC COMMENT='用户消息表';
CREATE TABLE `bolg_group_user` (
  `id` int(11) NOT NULL AUTO_INCREMENT,
  `group_id` int(11) NOT NULL COMMENT '群id',
  `user_id` int(11) NOT NULL COMMENT '用户id',
  `type` bigint(2) NOT NULL DEFAULT '0' COMMENT '用户类型 0用户 1管理员 2群主',
  `group_nick` varchar(255) NOT NULL COMMENT '备注',
  `add_time` datetime NOT NULL COMMENT '入群时间',
  `send_time` datetime NOT NULL COMMENT '发送消息时间',
  PRIMARY KEY (`id`) USING BTREE
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 ROW_FORMAT=DYNAMIC COMMENT='群用户';
CREATE TABLE `bolg_label` (
  `id` int(11) NOT NULL AUTO_INCREMENT,
  `label_name` varchar(255) NOT NULL COMMENT '标签名称',
  `create_time` datetime NOT NULL COMMENT '创建时间',
  PRIMARY KEY (`id`) USING BTREE
) ENGINE=InnoDB AUTO_INCREMENT=6 DEFAULT CHARSET=utf8mb4 ROW_FORMAT=DYNAMIC COMMENT='标签表';
CREATE TABLE `bolg_user` (
  `user_id` bigint(12) NOT NULL AUTO_INCREMENT,
  `user_name` varchar(255) NOT NULL COMMENT '用户名称',
  `account` varchar(255) NOT NULL COMMENT '账号',
  `password` varchar(255) NOT NULL COMMENT '密码',
  `gender` tinyint(2) NOT NULL DEFAULT '0' COMMENT '性别',
  `avatar` varchar(255) NOT NULL COMMENT '头像',
  `ip` varchar(255) NOT NULL COMMENT '用户ip',
  `login_time` datetime NOT NULL COMMENT '登录时间',
  `create_time` datetime NOT NULL COMMENT '创建时间',
  `update_time` datetime NOT NULL COMMENT '修改时间',
  `status` tinyint(2) NOT NULL DEFAULT '0' COMMENT '用户状态',
  PRIMARY KEY (`user_id`) USING BTREE
) ENGINE=InnoDB AUTO_INCREMENT=10000004 DEFAULT CHARSET=utf8mb4 ROW_FORMAT=DYNAMIC;
BEGIN;
LOCK TABLES `bolg`.`bolg_article` WRITE;
DELETE FROM `bolg`.`bolg_article`;
INSERT INTO `bolg`.`bolg_article` (`id`,`title`,`synopsis`,`cover`,`type`,`link`,`column_id`,`create_time`,`update_time`,`is_top`,`is_show`,`is_delete`) VALUES (1, '100%无压力学会安装Docker', '随着互联网的发展，容器技术越来越成熟。\n熟练掌握一门容器技术会给你的面试大大加分，Docker首当其冲是当今的热门的容器技术的选型。\n本文章讲介绍如何在Centos7上安装Docker。\n\n', 'https://ss2.bdstatic.com/70cFvXSh_Q1YnxGkpoWK1HF6hhy/it/u=810470186,1809147038&fm=253&gp=0.jpg', 1, NULL, 3, '2024-03-26 09:45:10', NULL, 0, 1, 0),(2, '看一遍闭着眼都会安装Lua了', '是一种轻量小巧的脚本语言，用标准C语言编写并以源代码形式开放， 其设计目的是为了嵌入应用程序中，从而为应用程序提供灵活的扩展和定制功能。\n\n\n\n', 'https://ss2.bdstatic.com/70cFvXSh_Q1YnxGkpoWK1HF6hhy/it/u=810470186,1809147038&fm=253&gp=0.jpg', 1, NULL, 1, '2024-03-26 09:45:23', NULL, 0, 1, 0),(3, '玩转Docker常用基本命令', '上一篇文章介绍了如何安装Docker，这篇文章将介绍一些常用的Docker命令。\n让你在职场能够轻松应对一些常见问题。\n\n', 'https://ss2.bdstatic.com/70cFvXSh_Q1YnxGkpoWK1HF6hhy/it/u=810470186,1809147038&fm=253&gp=0.jpg', 1, NULL, 3, '2024-03-26 09:45:23', NULL, 0, 1, 0),(4, 'SpringBoot发邮件', '发送邮件在java项目中是很常见的功能，本文章将介绍如何用Springboot快速优美的实现邮件发送。\n\n', 'https://ss2.bdstatic.com/70cFvXSh_Q1YnxGkpoWK1HF6hhy/it/u=810470186,1809147038&fm=253&gp=0.jpg', 1, NULL, 1, '2024-03-26 09:45:23', NULL, 0, 1, 0),(5, '纪伯伦 | 我曾经七次鄙视自己的灵魂', '我不知道什么是绝对的真理。但是我对于我的无知是谦虚的，这其中就有了我的荣誉和报酬。\n\n在人的幻想和成就中间有一段空间，只能靠他的热望来通过。\n\n天堂就在那边，在那扇门后，在隔壁的房里；但是我把钥匙丢了。\n\n', 'https://ss2.bdstatic.com/70cFvXSh_Q1YnxGkpoWK1HF6hhy/it/u=810470186,1809147038&fm=253&gp=0.jpg', 1, NULL, 1, '2024-03-26 09:45:23', NULL, 0, 1, 0),(6, 'java开发的idea小技巧', '在我们编码的时候熟练使用开发工具将会大大地提高我的开发效率，\n这篇文章将会分享几个实用的IDEA工具的小技巧\n\n', 'https://ss2.bdstatic.com/70cFvXSh_Q1YnxGkpoWK1HF6hhy/it/u=810470186,1809147038&fm=253&gp=0.jpg', 1, NULL, 1, '2024-03-26 09:45:23', NULL, 0, 1, 0),(7, 'Docker详细命令大全', '前面文章讲解了Docker的安装以及基本命令的使用，该文章将介绍Docker镜像命令，容器命令，容器数据卷，Dockerfile的构建，发布镜像，Docker网络等知识。\n\n', 'https://ss2.bdstatic.com/70cFvXSh_Q1YnxGkpoWK1HF6hhy/it/u=810470186,1809147038&fm=253&gp=0.jpg', 1, NULL, 3, '2024-03-26 09:45:23', NULL, 0, 1, 0),(8, 'python案例1-爬取优美桌面壁纸', '本章将介绍如何爬取网络上优美的壁纸，本案例仅当作案例参考学习使用，如果非法使用后果自行承担。\n\n', 'https://ss2.bdstatic.com/70cFvXSh_Q1YnxGkpoWK1HF6hhy/it/u=810470186,1809147038&fm=253&gp=0.jpg', 1, NULL, 1, '2024-03-26 09:45:23', NULL, 0, 1, 0),(9, '分布式缓存-缓存问题', '缓存在我们开发中经常被使用到，但是在使用中我们将注意哪些问题才能保证我们的服务高可用？\n这篇文章将以Redis为例，探讨一下在开发中需要注意哪些问题以及解决方案。', 'https://ss2.bdstatic.com/70cFvXSh_Q1YnxGkpoWK1HF6hhy/it/u=810470186,1809147038&fm=253&gp=0.jpg', 1, NULL, 2, '2024-03-26 09:45:23', NULL, 0, 1, 0),(10, '【面试准备】MySQL索引篇', '什么是索引？\nMySQL索引的结构有那些？\nB+tree在innodb与myisam存储引擎中有何区别?\n哪些需要创建索引？\n\n\n', 'https://ss2.bdstatic.com/70cFvXSh_Q1YnxGkpoWK1HF6hhy/it/u=810470186,1809147038&fm=253&gp=0.jpg', 1, NULL, 2, '2024-03-26 09:45:23', NULL, 0, 1, 0);
UNLOCK TABLES;
COMMIT;
BEGIN;
LOCK TABLES `bolg`.`bolg_article_column` WRITE;
DELETE FROM `bolg`.`bolg_article_column`;
INSERT INTO `bolg`.`bolg_article_column` (`id`,`name`,`is_show`,`is_delete`) VALUES (1, 'PHP', 1, 0),(2, 'MySql', 1, 0),(3, 'Docker', 1, 0);
UNLOCK TABLES;
COMMIT;
BEGIN;
LOCK TABLES `bolg`.`bolg_article_content` WRITE;
DELETE FROM `bolg`.`bolg_article_content`;
INSERT INTO `bolg`.`bolg_article_content` (`id`,`article_id`,`content`) VALUES (1, 1, '<p>@[TOC]</p>\r\n<p>##Centos7安装Docker</p>\r\n<h4 id=\"276\">1.更新yum</h4>\r\n<pre class=\"lang-shell\"><code data-language=\"shell\" class=\"hljs language-shell\">yum update\r\n</code></pre>\r\n<h4 id=\"373\">2.卸载旧版本(如果安装过旧版本的话)</h4>\r\n<pre class=\"lang-shell\"><code data-language=\"shell\" class=\"hljs language-shell\">yum remove -y docker \\\r\n                  docker-client \\\r\n                  docker-client-latest \\\r\n                  docker-common \\\r\n                  docker-latest \\\r\n                  docker-latest-logrotate \\\r\n                  docker-logrotate \\\r\n                  docker-selinux \\\r\n                  docker-engine-selinux \\\r\n                  docker-engine\r\n</code></pre>\r\n<h4 id=\"686\">3.安装需要的软件包， yum-util 提供yum-config-manager功能，另外两个是devicemapper驱动依赖的</h4>\r\n<pre class=\"lang-shell\"><code data-language=\"shell\" class=\"hljs language-shell\">yum install -y yum-utils device-mapper-persistent-data lvm2\r\n</code></pre>\r\n<h4 id=\"811\">4.添加Docker的存储库</h4>\r\n<pre class=\"lang-shell\"><code data-language=\"shell\" class=\"hljs language-shell\">yum-config-manager --add-repo https://download.docker.com/linux/centos/docker-ce.repo\r\n</code></pre>\r\n<h4 id=\"913\">5.安装Docker</h4>\r\n<pre class=\"lang-shell\"><code data-language=\"shell\" class=\"hljs language-shell\">yum install -y docker-ce\r\n<span class=\"hljs-meta prompt_\">#</span><span class=\"language-bash\">也可以安装指定版本 yum install docker-ce-17.12.0.ce</span>\r\n</code></pre>\r\n<h4 id=\"1034\">6.启动Docker并加入开机启动</h4>\r\n<pre class=\"lang-shell\"><code data-language=\"shell\" class=\"hljs language-shell\">systemctl start docker\r\nsystemctl enable docker\r\n</code></pre>\r\n<h4 id=\"1155\">7.验证安装</h4>\r\n<pre class=\"lang-shell\"><code data-language=\"shell\" class=\"hljs language-shell\">docker version\r\n</code></pre>\r\n<blockquote>\r\n<p>显示以下信息说明安装没问题！</p>\r\n<pre class=\"lang-shell\"><code data-language=\"shell\" class=\"hljs language-shell\">docker version\r\n</code></pre>\r\n</blockquote>\r\n<p>Client:<br>\r\nVersion: 17.12.1-ce<br>\r\nAPI version: 1.35<br>\r\nGo version: go1.9.4<br>\r\nGit commit: 7390fc6<br>\r\nBuilt: Tue Feb 27 22:15:20 2018<br>\r\nOS/Arch: linux/amd64</p>\r\n<p>Server:<br>\r\nEngine:<br>\r\nVersion: 17.12.1-ce<br>\r\nAPI version: 1.35 (minimum version 1.12)<br>\r\nGo version: go1.9.4<br>\r\nGit commit: 7390fc6<br>\r\nBuilt: Tue Feb 27 22:17:54 2018<br>\r\nOS/Arch: linux/amd64<br>\r\nExperimental: false</p>\r\n<blockquote>\r\n<pre><code class=\"hljs language-undefined\">\r\n</code></pre>\r\n</blockquote>\r\n<h4 id=\"1905\">8.Docker重启</h4>\r\n<pre class=\"lang-shell\"><code data-language=\"shell\" class=\"hljs language-shell\">systemctl restart docker\r\n</code></pre>'),(2, 2, '<p>@[TOC]</p>\r\n<h4 id=\"235\">引言：</h4>\r\n<p>Lua 是一种轻量小巧的脚本语言，能为应用程序提供灵活的扩展和定制功能。</p>\r\n<h4 id=\"320\">Lua 应用场景</h4>\r\n<ul>\r\n<li>游戏开发</li>\r\n<li>独立应用脚本</li>\r\n<li>Web 应用脚本</li>\r\n<li>扩展和数据库插件如：MySQL Proxy 和 MySQL WorkBench</li>\r\n<li>安全系统，如入侵检测系统</li>\r\n</ul>\r\n<hr>\r\n<h4 id=\"530\">安装</h4>\r\n<pre class=\"lang-shell\"><code data-language=\"shell\" class=\"hljs language-shell\">- curl -R -O http://www.lua.org/ftp/lua-5.3.5.tar.gz #下载\r\n- tar zxf lua-5.3.5.tar.gz #解压\r\n- cd lua-5.3.3 #进入解压文件夹\r\n- make linux test #安装&amp;测试\r\n</code></pre>\r\n<hr>\r\n<h4 id=\"733\">安装过程可能出现的问题</h4>\r\n<ol>\r\n<li>没有gcc命令(lua是C语言编写的，安装时依赖gcc)</li>\r\n</ol>\r\n<blockquote>\r\n<p>使用<code data-backticks=\"1\">which gcc</code>命令可以查看是否有gcc，如果没有使用下面命令进行安装gcc 与gcc-c++，</p>\r\n<pre class=\"lang-shell\"><code data-language=\"shell\" class=\"hljs language-shell\">yum -y install gcc\r\n</code></pre>\r\n</blockquote>\r\n<p>yum -y install gcc-c++</p>\r\n<blockquote>\r\n<pre><code class=\"hljs language-undefined\">\r\n</code></pre>\r\n</blockquote>\r\n<hr>\r\n<ol start=\"2\">\r\n<li>致命错误：readline/readline.h：没有那个文件或目录</li>\r\n</ol>\r\n<blockquote>\r\n<p>执行如下命令即可:</p>\r\n<pre class=\"lang-shell\"><code data-language=\"shell\" class=\"hljs language-shell\">yum install libtermcap-devel ncurses-devel libevent-devel readline-devel\r\n</code></pre>\r\n</blockquote>\r\n<hr>\r\n<h4 id=\"1281\">安装成功验证</h4>\r\n<blockquote>\r\n<p>执行<code data-backticks=\"1\">lua -v</code>,出现如下信息代表安装成功<br>\r\nLua 5.1.4 Copyright (C) 1994-2008 Lua.org, PUC-Rio</p>\r\n</blockquote>\r\n<pre class=\"lang-shell\"><code data-language=\"shell\" class=\"hljs language-shell\">lua -v\r\n</code></pre>'),(3, 3, '<p>@[TOC]</p>\r\n<h4 id=\"235\">1.配置镜像源（国内地址镜像加速）</h4>\r\n<p>Docker中国区官方镜像：<code data-backticks=\"1\">https://registry.docker-cn.com</code><br>\r\n阿里镜像：<code data-backticks=\"1\">https://cr.console.aliyun.com/</code>(需要去获取个人地址)<br>\r\nustc：<code data-backticks=\"1\">https://docker.mirrors.ustc.edu.cn</code><br>\r\n网易: <code data-backticks=\"1\">http://hub-mirror.c.163.com</code><br>\r\n中国科技大学：<code data-backticks=\"1\">https://docker.mirrors.ustc.edu.cn</code></p>\r\n<pre class=\"lang-shell\"><code data-language=\"shell\" class=\"hljs language-shell\"><span class=\"hljs-meta prompt_\">#</span><span class=\"language-bash\">如果没有该文件，新建一个</span>\r\nvim /etc/docker/daemon.json\r\n</code></pre>\r\n<p>改为加速地址</p>\r\n<pre class=\"lang-json\"><code data-language=\"json\" class=\"hljs language-json\"><span class=\"hljs-punctuation\">{</span>\r\n  <span class=\"hljs-attr\">\"registry-mirrors\"</span><span class=\"hljs-punctuation\">:</span> <span class=\"hljs-punctuation\">[</span><span class=\"hljs-string\">\"加速地址\"</span><span class=\"hljs-punctuation\">]</span>\r\n<span class=\"hljs-punctuation\">}</span>\r\n</code></pre>\r\n<p>重启使配置文件生效</p>\r\n<pre class=\"lang-shell\"><code data-language=\"shell\" class=\"hljs language-shell\">systemctl daemon-reload\r\nsystemctl restart docker\r\n</code></pre>\r\n<hr>\r\n<h4 id=\"795\">2.搜索镜像</h4>\r\n<pre class=\"lang-shell\"><code data-language=\"shell\" class=\"hljs language-shell\"><span class=\"hljs-meta prompt_\">#</span><span class=\"language-bash\"><span class=\"hljs-comment\"># 比如查看nginx各个版本</span></span>\r\ndocker search nginx\r\n</code></pre>\r\n<hr>\r\n<h4 id=\"950\">3.查看镜像列表</h4>\r\n<pre class=\"lang-shell\"><code data-language=\"shell\" class=\"hljs language-shell\">docker images\r\n</code></pre>\r\n<hr>\r\n<h4 id=\"1081\">4.拉取镜像</h4>\r\n<blockquote>\r\n<p>缺省version号默认拉取latest版本</p>\r\n</blockquote>\r\n<pre class=\"lang-shell\"><code data-language=\"shell\" class=\"hljs language-shell\">docker pull $image-name:version\r\n</code></pre>\r\n<hr>\r\n<h4 id=\"1283\">5.容器启动</h4>\r\n<blockquote>\r\n<p>参数说明<br>\r\n<code data-backticks=\"1\">-d</code>:容器后台运行，或者<code data-backticks=\"1\">-d=true</code><br>\r\n<code data-backticks=\"1\">-p</code>:主机与容器端口映射（主机:容器）<br>\r\n<code data-backticks=\"1\">--name</code>:给容器命名（缺省docker自动给容器命名）,<code data-backticks=\"1\">--name $new-name</code>或者<code data-backticks=\"1\">--name=$new-name</code><br>\r\n其他常用参数<br>\r\n<code data-backticks=\"1\">-i</code>:交互式操作<br>\r\n<code data-backticks=\"1\">-t</code>:虚拟终端（一般-it一起使用）<br>\r\n<code data-backticks=\"1\">--dns 8.8.8.8</code>:指定容器使用的DNS服务器，默认和宿主一致<br>\r\n<a href=\"https://www.runoob.com/docker/docker-run-command.html\">更多参数</a>查看</p>\r\n</blockquote>\r\n<pre class=\"lang-shell\"><code data-language=\"shell\" class=\"hljs language-shell\">docker run -d -p 5000:5000 --name $new-name $image-name\r\n</code></pre>\r\n<hr>\r\n<h4 id=\"1719\">6.容器运行状态</h4>\r\n<pre class=\"lang-shell\"><code data-language=\"shell\" class=\"hljs language-shell\">docker ps #运行中的容器\r\ndocker ps -a #所有容器,包括未运行的。\r\ndocker ps -l #显示最近创建的容器\r\n</code></pre>\r\n<hr>\r\n<h4 id=\"1898\">7.移除容器</h4>\r\n<pre class=\"lang-shell\"><code data-language=\"shell\" class=\"hljs language-shell\">docker rm $name\r\ndocker rm -f $name #强制删除,包含运行中容器\r\n</code></pre>\r\n<hr>\r\n<h4 id=\"2053\">8.移除镜像</h4>\r\n<pre class=\"lang-shell\"><code data-language=\"shell\" class=\"hljs language-shell\">docker rmi -f $image-name\r\n</code></pre>'),(4, 4, '<h4 id=\"194\">依赖</h4>\r\n<pre class=\"lang-xml\"><code data-language=\"xml\" class=\"hljs language-xml\"><span class=\"hljs-tag\">&lt;<span class=\"hljs-name\">dependency</span>&gt;</span>\r\n	<span class=\"hljs-tag\">&lt;<span class=\"hljs-name\">groupId</span>&gt;</span>org.springframework.boot<span class=\"hljs-tag\">&lt;/<span class=\"hljs-name\">groupId</span>&gt;</span>\r\n	<span class=\"hljs-tag\">&lt;<span class=\"hljs-name\">artifactId</span>&gt;</span>spring-boot-starter-mail<span class=\"hljs-tag\">&lt;/<span class=\"hljs-name\">artifactId</span>&gt;</span>\r\n<span class=\"hljs-tag\">&lt;/<span class=\"hljs-name\">dependency</span>&gt;</span>\r\n</code></pre>\r\n<hr>\r\n<h4 id=\"397\">邮箱配置</h4>\r\n<pre class=\"lang-yaml\"><code data-language=\"yaml\" class=\"hljs language-yaml\"><span class=\"hljs-attr\">spring:</span>\r\n  <span class=\"hljs-attr\">application:</span>\r\n    <span class=\"hljs-attr\">name:</span> <span class=\"hljs-string\">maildemo</span>\r\n  <span class=\"hljs-attr\">mail:</span>\r\n    <span class=\"hljs-attr\">username:</span> <span class=\"hljs-string\">server@fengziy.cn</span>\r\n    <span class=\"hljs-attr\">default-encoding:</span> <span class=\"hljs-string\">utf-8</span>\r\n    <span class=\"hljs-attr\">host:</span> <span class=\"hljs-string\">smtp.exmail.qq.com</span>\r\n    <span class=\"hljs-attr\">password:</span> <span class=\"hljs-string\">xxxxxxxxx</span> <span class=\"hljs-comment\"># 邮箱服务的密码，并非邮箱登陆密码</span>\r\n    <span class=\"hljs-attr\">from:</span> <span class=\"hljs-string\">server@fengziy.cn</span>\r\n    <span class=\"hljs-attr\">properties:</span>\r\n      <span class=\"hljs-attr\">mail:</span>\r\n        <span class=\"hljs-attr\">smtp:</span>\r\n          <span class=\"hljs-attr\">auth:</span> <span class=\"hljs-literal\">true</span>\r\n          <span class=\"hljs-attr\">starttls:</span>\r\n            <span class=\"hljs-attr\">enable:</span> <span class=\"hljs-literal\">true</span>\r\n            <span class=\"hljs-attr\">required:</span> <span class=\"hljs-literal\">true</span>\r\n          <span class=\"hljs-attr\">socketFactory:</span>\r\n            <span class=\"hljs-attr\">class:</span> <span class=\"hljs-string\">javax.net.ssl.SSLSocketFactory</span>\r\n            <span class=\"hljs-attr\">port:</span> <span class=\"hljs-number\">465</span>\r\n</code></pre>\r\n<hr>\r\n<h4 id=\"960\">发送简单邮件</h4>\r\n<pre class=\"lang-java\"><code data-language=\"java\" class=\"hljs language-java\">	<span class=\"hljs-meta\">@Autowired</span>\r\n    <span class=\"hljs-keyword\">private</span> JavaMailSender mailSender;\r\n\r\n    <span class=\"hljs-comment\">/**\r\n     * 配置文件中邮箱服务\r\n     */</span>\r\n    <span class=\"hljs-meta\">@Value(\"${spring.mail.from}\")</span>\r\n    <span class=\"hljs-keyword\">private</span> String from;\r\n\r\n    <span class=\"hljs-comment\">/**\r\n     * 简单文本邮件\r\n     * <span class=\"hljs-doctag\">@param</span> to 收件人\r\n     * <span class=\"hljs-doctag\">@param</span> subject 主题\r\n     * <span class=\"hljs-doctag\">@param</span> content 内容\r\n     */</span>\r\n    <span class=\"hljs-keyword\">public</span> <span class=\"hljs-keyword\">void</span> <span class=\"hljs-title function_\">sendSimpleMail</span><span class=\"hljs-params\">(String to, String subject, String content)</span> {\r\n        <span class=\"hljs-comment\">//创建SimpleMailMessage对象</span>\r\n        <span class=\"hljs-type\">SimpleMailMessage</span> <span class=\"hljs-variable\">message</span> <span class=\"hljs-operator\">=</span> <span class=\"hljs-keyword\">new</span> <span class=\"hljs-title class_\">SimpleMailMessage</span>();\r\n        <span class=\"hljs-comment\">//邮件发送人</span>\r\n        message.setFrom(from);\r\n        <span class=\"hljs-comment\">//邮件接收人</span>\r\n        message.setTo(to);\r\n        <span class=\"hljs-comment\">//邮件主题</span>\r\n        message.setSubject(subject);\r\n        <span class=\"hljs-comment\">//邮件内容</span>\r\n        message.setText(content);\r\n        <span class=\"hljs-comment\">//发送邮件</span>\r\n        mailSender.send(message);\r\n    }\r\n</code></pre>\r\n<hr>\r\n<h4 id=\"1763\">发送html邮件</h4>\r\n<pre class=\"lang-java\"><code data-language=\"java\" class=\"hljs language-java\"><span class=\"hljs-comment\">/**\r\n     * html邮件\r\n     * <span class=\"hljs-doctag\">@param</span> to 收件人\r\n     * <span class=\"hljs-doctag\">@param</span> subject 主题\r\n     * <span class=\"hljs-doctag\">@param</span> content 内容\r\n     */</span>\r\n    <span class=\"hljs-keyword\">public</span> <span class=\"hljs-keyword\">void</span> <span class=\"hljs-title function_\">sendHtmlMail</span><span class=\"hljs-params\">(String to, String subject, String content)</span> {\r\n        <span class=\"hljs-comment\">//获取MimeMessage对象</span>\r\n        <span class=\"hljs-type\">MimeMessage</span> <span class=\"hljs-variable\">message</span> <span class=\"hljs-operator\">=</span> mailSender.createMimeMessage();\r\n        MimeMessageHelper messageHelper;\r\n        <span class=\"hljs-keyword\">try</span> {\r\n            messageHelper = <span class=\"hljs-keyword\">new</span> <span class=\"hljs-title class_\">MimeMessageHelper</span>(message, <span class=\"hljs-literal\">true</span>);\r\n            <span class=\"hljs-comment\">//邮件发送人</span>\r\n            messageHelper.setFrom(from);\r\n            <span class=\"hljs-comment\">//邮件接收人</span>\r\n            messageHelper.setTo(to);\r\n            <span class=\"hljs-comment\">//邮件主题</span>\r\n            message.setSubject(subject);\r\n            <span class=\"hljs-comment\">//邮件内容，html格式</span>\r\n            messageHelper.setText(content, <span class=\"hljs-literal\">true</span>);\r\n            <span class=\"hljs-comment\">//发送</span>\r\n            mailSender.send(message);\r\n            <span class=\"hljs-comment\">//日志信息</span>\r\n        } <span class=\"hljs-keyword\">catch</span> (MessagingException e) {\r\n        	<span class=\"hljs-comment\">// todo:</span>\r\n        }\r\n    }\r\n</code></pre>\r\n<hr>\r\n<h4 id=\"2518\">发送模板邮件</h4>\r\n<h5 id=\"2562\">1. 引入thymeleaf模板引擎</h5>\r\n<pre class=\"lang-xml\"><code data-language=\"xml\" class=\"hljs language-xml\"><span class=\"hljs-tag\">&lt;<span class=\"hljs-name\">dependency</span>&gt;</span>\r\n    <span class=\"hljs-tag\">&lt;<span class=\"hljs-name\">groupId</span>&gt;</span>org.springframework.boot<span class=\"hljs-tag\">&lt;/<span class=\"hljs-name\">groupId</span>&gt;</span>\r\n    <span class=\"hljs-tag\">&lt;<span class=\"hljs-name\">artifactId</span>&gt;</span>spring-boot-starter-thymeleaf<span class=\"hljs-tag\">&lt;/<span class=\"hljs-name\">artifactId</span>&gt;</span>\r\n<span class=\"hljs-tag\">&lt;/<span class=\"hljs-name\">dependency</span>&gt;</span>\r\n</code></pre>\r\n<hr>\r\n<h5 id=\"2763\">2.创建模板</h5>\r\n<blockquote>\r\n<p>resources/templates 文件夹下创建 mailCode.html 邮箱验证码模板<br>\r\nhtml标签加上 xmlns:th=\"http://www.thymeleaf.org\" 模板引擎语法检查</p>\r\n</blockquote>\r\n<pre class=\"lang-html\"><code data-language=\"html\" class=\"hljs language-xml\"><span class=\"hljs-meta\">&lt;!DOCTYPE <span class=\"hljs-keyword\">html</span>&gt;</span>\r\n<span class=\"hljs-tag\">&lt;<span class=\"hljs-name\">html</span> <span class=\"hljs-attr\">xmlns:th</span>=<span class=\"hljs-string\">\"http://www.thymeleaf.org\"</span> <span class=\"hljs-attr\">lang</span>=<span class=\"hljs-string\">\"en\"</span>&gt;</span>\r\n<span class=\"hljs-tag\">&lt;<span class=\"hljs-name\">head</span>&gt;</span>\r\n    <span class=\"hljs-tag\">&lt;<span class=\"hljs-name\">meta</span> <span class=\"hljs-attr\">charset</span>=<span class=\"hljs-string\">\"UTF-8\"</span>&gt;</span>\r\n    <span class=\"hljs-tag\">&lt;<span class=\"hljs-name\">title</span>&gt;</span>留言通知<span class=\"hljs-tag\">&lt;/<span class=\"hljs-name\">title</span>&gt;</span>\r\n<span class=\"hljs-tag\">&lt;/<span class=\"hljs-name\">head</span>&gt;</span>\r\n<span class=\"hljs-tag\">&lt;<span class=\"hljs-name\">body</span>&gt;</span>\r\n<span class=\"hljs-tag\">&lt;<span class=\"hljs-name\">div</span> <span class=\"hljs-attr\">style</span>=<span class=\"hljs-string\">\"padding: 20px;\"</span>&gt;</span>\r\n    <span class=\"hljs-tag\">&lt;<span class=\"hljs-name\">p</span>&gt;</span>您正在<span class=\"hljs-tag\">&lt;<span class=\"hljs-name\">a</span> <span class=\"hljs-attr\">href</span>=<span class=\"hljs-string\">\"https://www.fengziy.cn\"</span>&gt;</span>Gblog<span class=\"hljs-tag\">&lt;/<span class=\"hljs-name\">a</span>&gt;</span>博客使用邮箱验证，验证码 |\r\n        <span class=\"hljs-tag\">&lt;<span class=\"hljs-name\">span</span> <span class=\"hljs-attr\">th:text</span>=<span class=\"hljs-string\">\"${code}\"</span> <span class=\"hljs-attr\">style</span>=<span class=\"hljs-string\">\"color: royalblue;\"</span>&gt;</span><span class=\"hljs-tag\">&lt;/<span class=\"hljs-name\">span</span>&gt;</span>,有效期\r\n        <span class=\"hljs-tag\">&lt;<span class=\"hljs-name\">span</span> <span class=\"hljs-attr\">th:text</span>=<span class=\"hljs-string\">\"${expire}\"</span> <span class=\"hljs-attr\">style</span>=<span class=\"hljs-string\">\"color: darkgray;\"</span>&gt;</span>120s<span class=\"hljs-tag\">&lt;/<span class=\"hljs-name\">span</span>&gt;</span>。\r\n    <span class=\"hljs-tag\">&lt;/<span class=\"hljs-name\">p</span>&gt;</span>\r\n    <span class=\"hljs-tag\">&lt;<span class=\"hljs-name\">p</span>&gt;</span>若非本人操作，请勿泄露。<span class=\"hljs-tag\">&lt;/<span class=\"hljs-name\">p</span>&gt;</span>\r\n    <span class=\"hljs-tag\">&lt;<span class=\"hljs-name\">hr</span> <span class=\"hljs-attr\">style</span>=<span class=\"hljs-string\">\"height: 1px;border: 0;width: 100%;background-color: #e3e3e3;\"</span>/&gt;</span>\r\n    <span class=\"hljs-tag\">&lt;<span class=\"hljs-name\">p</span> <span class=\"hljs-attr\">style</span>=<span class=\"hljs-string\">\"font-size: 14px;color: #6d6d6d;\"</span>&gt;</span>此为系统邮件请勿回复<span class=\"hljs-tag\">&lt;/<span class=\"hljs-name\">p</span>&gt;</span>\r\n<span class=\"hljs-tag\">&lt;/<span class=\"hljs-name\">div</span>&gt;</span>\r\n<span class=\"hljs-tag\">&lt;/<span class=\"hljs-name\">body</span>&gt;</span>\r\n<span class=\"hljs-tag\">&lt;/<span class=\"hljs-name\">html</span>&gt;</span>\r\n</code></pre>\r\n<hr>\r\n<h5 id=\"3397\">3.解析模板发送邮件</h5>\r\n<pre class=\"lang-java\"><code data-language=\"java\" class=\"hljs language-java\"><span class=\"hljs-meta\">@Resource</span>\r\n<span class=\"hljs-keyword\">private</span> TemplateEngine templateEngine;\r\n\r\n<span class=\"hljs-keyword\">public</span> <span class=\"hljs-keyword\">void</span> <span class=\"hljs-title function_\">sendMailVerifyMail</span><span class=\"hljs-params\">(String verifyMail,String code)</span>{\r\n        Map&lt;String,Object&gt; map =<span class=\"hljs-keyword\">new</span> <span class=\"hljs-title class_\">HashMap</span>&lt;&gt;(<span class=\"hljs-number\">2</span>);\r\n        map.put(<span class=\"hljs-string\">\"code\"</span>,code); <span class=\"hljs-comment\">// 模板参数</span>\r\n        map.put(<span class=\"hljs-string\">\"expire\"</span>,<span class=\"hljs-string\">\"120s\"</span>);\r\n        sendTemplateMail(verifyMail,<span class=\"hljs-string\">\"邮箱验证\"</span>,<span class=\"hljs-string\">\"mailCode\"</span>,map);\r\n    }\r\n\r\n<span class=\"hljs-keyword\">public</span> <span class=\"hljs-keyword\">void</span> <span class=\"hljs-title function_\">sendTemplateMail</span><span class=\"hljs-params\">(String to, String subject, String template, Map&lt;String,Object&gt; params)</span> {\r\n        <span class=\"hljs-type\">Context</span> <span class=\"hljs-variable\">context</span> <span class=\"hljs-operator\">=</span> <span class=\"hljs-keyword\">new</span> <span class=\"hljs-title class_\">Context</span>();\r\n        context.setVariables(params);\r\n        <span class=\"hljs-type\">String</span> <span class=\"hljs-variable\">process</span> <span class=\"hljs-operator\">=</span> templateEngine.process(template, context);\r\n        sendHtmlMail(to,subject,process);\r\n    }\r\n</code></pre>'),(5, 5, '<p><strong>也许这就是人性的弱点</strong></p>\r\n<hr>\r\n<blockquote>\r\n<ul>\r\n<li>第一次，当它本可进取时，却故作谦卑；</li>\r\n<li>第二次，当它在空虚时，用爱欲来填充；</li>\r\n<li>第三次，在困难和容易之间，它选择了容易；</li>\r\n<li>第四次，它犯了错，却借由别人也会犯错来宽慰自己；</li>\r\n<li>第五次，它自由软弱，却把它认为是生命的坚韧；</li>\r\n<li>第六次，当它鄙夷一张丑恶的嘴脸时，却不知那正是自己面具中的一副；</li>\r\n<li>第七次，它侧身于生活的污泥中，虽不甘心，却又畏首畏尾。</li>\r\n</ul>\r\n</blockquote>\r\n<hr>\r\n<p><a href=\"https://imgchr.com/i/Dcb4qH\"><img src=\"https://s3.ax1x.com/2020/11/29/Dcb4qH.jpg\" alt=\"Dcb4qH.jpg\"></a></p>\r\n<p><strong>我不知道什么是绝对的真理。但是我对于我的无知是谦虚的，这其中就有了我的荣誉和报酬。</strong></p>\r\n<p><strong>在人的幻想和成就中间有一段空间，只能靠他的热望来通过。</strong></p>\r\n<p><strong>天堂就在那边，在那扇门后，在隔壁的房里；但是我把钥匙丢了。</strong></p>\r\n<p><strong>也许我只是把它放错了地方。</strong></p>\r\n<p><strong>你瞎了眼睛，我是又聋又哑，因此让我们握起手来互相了解吧。</strong></p>\r\n<p><strong>一个人的意义不在于他的成就，而在于他所企求成就的东西。</strong></p>\r\n<p><strong>我们中间，有些人像墨水，有些人像纸张。</strong></p>\r\n<p><strong>若不是因为有些人是黑的话，有些人就成了哑吧。</strong></p>\r\n<p><strong>若不是因为有些人是白的话，有些人就成了瞎子。</strong></p>\r\n<p><strong>给我一只耳朵，我将给你以声音。</strong></p>\r\n<p><strong>我们的心才是一块海绵；我们的心怀是一道河水。</strong></p>\r\n<p><strong>然而我们大多宁愿吸收而不肯奔流，这不是很奇怪吗？</strong></p>\r\n<p><strong>当你想望着无名的恩赐，怀抱着无端的烦恼的时候，你就真和一切生物一同长大，升向你的大我。</strong></p>\r\n<p><strong>一个人的实质，不在于他向你显露的那一面，而在于他所不能向你显露的那一面。</strong></p>\r\n<p><strong>因此，如果你想了解他，不要去听他说出的话，而要去听他的没有说出的话。</strong></p>\r\n<p><strong>我说的话有一半是没有意义的；我把它说出来，为的是也许会让你听到其他的一半。</strong></p>\r\n<p><strong>幽默感就是分寸感。</strong></p>\r\n<p><strong>当人们夸奖我多言的过失，责备我沉默的美德的时候，我的寂寞就产生了。</strong></p>\r\n<p><a href=\"https://imgchr.com/i/DcbyI1\"><img src=\"https://s3.ax1x.com/2020/11/29/DcbyI1.md.jpg\" alt=\"DcbyI1.md.jpg\"></a></p>'),(6, 6, '<h4 id=\"194\">快速生成 if 语句</h4>\r\n<blockquote>\r\n<p>判断条件.if + [tab键]</p>\r\n</blockquote>\r\n<pre class=\"lang-java\"><code data-language=\"java\" class=\"hljs language-java\"><span class=\"hljs-keyword\">public</span> <span class=\"hljs-keyword\">class</span> <span class=\"hljs-title class_\">Test</span> {\r\n    <span class=\"hljs-keyword\">public</span> <span class=\"hljs-keyword\">static</span> <span class=\"hljs-keyword\">void</span> <span class=\"hljs-title function_\">main</span><span class=\"hljs-params\">(String[] args)</span> {\r\n        <span class=\"hljs-type\">int</span> <span class=\"hljs-variable\">a</span> <span class=\"hljs-operator\">=</span> <span class=\"hljs-number\">1</span>;\r\n        <span class=\"hljs-comment\">// a == 1.if + [tab键]</span>\r\n        <span class=\"hljs-keyword\">if</span> (a == <span class=\"hljs-number\">1</span>) {\r\n        }\r\n    }\r\n}\r\n</code></pre>\r\n<h4 id=\"530\">快速生成 for 语句</h4>\r\n<blockquote>\r\n<ol>\r\n<li>数据集.for + [tab键]</li>\r\n<li>数据集.fori + [tab键]</li>\r\n<li>数据集.forr + [tab键]</li>\r\n</ol>\r\n</blockquote>\r\n<h5 id=\"694\">foreach语句</h5>\r\n<pre class=\"lang-java\"><code data-language=\"java\" class=\"hljs language-java\"><span class=\"hljs-keyword\">public</span> <span class=\"hljs-keyword\">class</span> <span class=\"hljs-title class_\">Test</span> {\r\n    <span class=\"hljs-keyword\">public</span> <span class=\"hljs-keyword\">static</span> <span class=\"hljs-keyword\">void</span> <span class=\"hljs-title function_\">main</span><span class=\"hljs-params\">(String[] args)</span> {\r\n        List&lt;String&gt; list = <span class=\"hljs-keyword\">new</span> <span class=\"hljs-title class_\">ArrayList</span>&lt;&gt;();\r\n        <span class=\"hljs-comment\">// list.for + [tab键]</span>\r\n        <span class=\"hljs-keyword\">for</span> (String s : list) {\r\n        }\r\n    }\r\n}\r\n</code></pre>\r\n<h5 id=\"957\">for带索引语句</h5>\r\n<pre class=\"lang-java\"><code data-language=\"java\" class=\"hljs language-java\"><span class=\"hljs-keyword\">public</span> <span class=\"hljs-keyword\">class</span> <span class=\"hljs-title class_\">Test</span> {\r\n    <span class=\"hljs-keyword\">public</span> <span class=\"hljs-keyword\">static</span> <span class=\"hljs-keyword\">void</span> <span class=\"hljs-title function_\">main</span><span class=\"hljs-params\">(String[] args)</span> {\r\n        List&lt;String&gt; list = <span class=\"hljs-keyword\">new</span> <span class=\"hljs-title class_\">ArrayList</span>&lt;&gt;();\r\n        <span class=\"hljs-comment\">// list.fori + [tab键]</span>\r\n        <span class=\"hljs-keyword\">for</span> (<span class=\"hljs-type\">int</span> <span class=\"hljs-variable\">i</span> <span class=\"hljs-operator\">=</span> <span class=\"hljs-number\">0</span>; i &lt; list.size(); i++) {\r\n        }\r\n    }\r\n}\r\n</code></pre>\r\n<h5 id=\"1220\">for倒序遍历</h5>\r\n<pre class=\"lang-java\"><code data-language=\"java\" class=\"hljs language-java\"><span class=\"hljs-keyword\">public</span> <span class=\"hljs-keyword\">class</span> <span class=\"hljs-title class_\">Test</span> {\r\n    <span class=\"hljs-keyword\">public</span> <span class=\"hljs-keyword\">static</span> <span class=\"hljs-keyword\">void</span> <span class=\"hljs-title function_\">main</span><span class=\"hljs-params\">(String[] args)</span> {\r\n        List&lt;String&gt; list = <span class=\"hljs-keyword\">new</span> <span class=\"hljs-title class_\">ArrayList</span>&lt;&gt;();\r\n        <span class=\"hljs-comment\">// list.forr + [tab键]</span>\r\n        <span class=\"hljs-keyword\">for</span> (<span class=\"hljs-type\">int</span> <span class=\"hljs-variable\">i</span> <span class=\"hljs-operator\">=</span> list.size() - <span class=\"hljs-number\">1</span>; i &gt;= <span class=\"hljs-number\">0</span>; i--) {\r\n        }\r\n    }\r\n}\r\n</code></pre>\r\n<h4 id=\"1483\">判空（非空）生成</h4>\r\n<blockquote>\r\n<p>变量.null + [tab键]<br>\r\n变量.nn + [tab键]</p>\r\n</blockquote>\r\n<h5 id=\"1624\">判空</h5>\r\n<pre class=\"lang-java\"><code data-language=\"java\" class=\"hljs language-java\"><span class=\"hljs-keyword\">public</span> <span class=\"hljs-keyword\">class</span> <span class=\"hljs-title class_\">Test</span> {\r\n    <span class=\"hljs-keyword\">public</span> <span class=\"hljs-keyword\">static</span> <span class=\"hljs-keyword\">void</span> <span class=\"hljs-title function_\">main</span><span class=\"hljs-params\">(String[] args)</span> {\r\n        List&lt;String&gt; list = <span class=\"hljs-keyword\">new</span> <span class=\"hljs-title class_\">ArrayList</span>&lt;&gt;();\r\n        <span class=\"hljs-comment\">// list.null + [tab键]</span>\r\n        <span class=\"hljs-keyword\">if</span> (list == <span class=\"hljs-literal\">null</span>) {\r\n        }\r\n    }\r\n}\r\n</code></pre>\r\n<h5 id=\"1887\">判非空</h5>\r\n<pre class=\"lang-java\"><code data-language=\"java\" class=\"hljs language-java\"><span class=\"hljs-keyword\">public</span> <span class=\"hljs-keyword\">class</span> <span class=\"hljs-title class_\">Test</span> {\r\n    <span class=\"hljs-keyword\">public</span> <span class=\"hljs-keyword\">static</span> <span class=\"hljs-keyword\">void</span> <span class=\"hljs-title function_\">main</span><span class=\"hljs-params\">(String[] args)</span> {\r\n        List&lt;String&gt; list = <span class=\"hljs-keyword\">new</span> <span class=\"hljs-title class_\">ArrayList</span>&lt;&gt;();\r\n        <span class=\"hljs-comment\">// list.nn + [tab键]</span>\r\n        <span class=\"hljs-keyword\">if</span> (list != <span class=\"hljs-literal\">null</span>) {\r\n        }\r\n    }\r\n}\r\n</code></pre>\r\n<h4 id=\"2150\">打印输出</h4>\r\n<blockquote>\r\n<p>变量.sout + [tab键]<br>\r\n变量.soutv + [tab键]</p>\r\n</blockquote>\r\n<pre class=\"lang-java\"><code data-language=\"java\" class=\"hljs language-java\"><span class=\"hljs-keyword\">public</span> <span class=\"hljs-keyword\">class</span> <span class=\"hljs-title class_\">Test</span> {\r\n    <span class=\"hljs-keyword\">public</span> <span class=\"hljs-keyword\">static</span> <span class=\"hljs-keyword\">void</span> <span class=\"hljs-title function_\">main</span><span class=\"hljs-params\">(String[] args)</span> {\r\n        List&lt;String&gt; list = <span class=\"hljs-keyword\">new</span> <span class=\"hljs-title class_\">ArrayList</span>&lt;&gt;();\r\n        <span class=\"hljs-comment\">// list.sout + [tab键]</span>\r\n        System.out.println(list);\r\n        <span class=\"hljs-comment\">// list.soutv + [tab键]</span>\r\n        System.out.println(<span class=\"hljs-string\">\"list = \"</span> + list);\r\n    }\r\n}\r\n</code></pre>'),(7, 7, '<h2 id=\"194\">Docker的常用命令</h2>\r\n<hr>\r\n<h3 id=\"275\">帮助命令</h3>\r\n<hr>\r\n<pre class=\"lang-shell\"><code data-language=\"shell\" class=\"hljs language-shell\">docker version #显示docker的版本信息\r\ndocker info #显示docker的系统命令\r\ndocker 命令 --help #万能\r\n</code></pre>\r\n<p>中文文档：[http://c.biancheng.net/docker/(http://c.biancheng.net/docke)</p>\r\n<hr>\r\n<h3 id=\"530\">镜像命令</h3>\r\n<hr>\r\n<h4 id=\"609\">docker images #查看所有镜像</h4>\r\n<pre class=\"lang-shell\"><code data-language=\"shell\" class=\"hljs language-shell\">[root@192 wfeng]# docker images\r\nREPOSITORY   TAG       IMAGE ID   CREATED   SIZE\r\n<span class=\"hljs-meta prompt_\"># </span><span class=\"language-bash\">解释</span>\r\nREPOSITORY 镜像的仓库源\r\nTAG		   镜像的标签\r\nIMAGE ID   镜像的id\r\nCERATED    镜像创建的时间\r\nSIZE	   镜像的大小\r\n<span class=\"hljs-meta prompt_\">\r\n#</span><span class=\"language-bash\">可选项</span>\r\n-a, --all	# 列出所有镜像\r\n-q, --quiet # 只显示镜像的id\r\n</code></pre>\r\n<h4 id=\"970\">docker search # 镜像搜索</h4>\r\n<pre class=\"lang-shell\"><code data-language=\"shell\" class=\"hljs language-shell\">[root@192 wfeng]# docker search mysql\r\nNAME                              DESCRIPTION                                     STARS     OFFICIAL   AUTOMATED\r\nmysql                             MySQL is a widely used, open-source relation…   11610     [OK]\r\nmariadb                           MariaDB Server is a high performing open sou…   4417      [OK]\r\nmysql/mysql-server                Optimized MySQL Server Docker images. Create…   857                  [OK]\r\n<span class=\"hljs-meta prompt_\">\r\n# </span><span class=\"language-bash\">可选项</span>\r\n-f,--filter # -f=STARS=3000 搜索镜像STARS&gt;3000的\r\n</code></pre>\r\n<h4 id=\"1240\">docker pull 下载镜像</h4>\r\n<pre class=\"lang-shell\"><code data-language=\"shell\" class=\"hljs language-shell\"><span class=\"hljs-meta prompt_\"># </span><span class=\"language-bash\">下载镜像 docker pull 镜像名[:tag]</span>\r\n[root@192 wfeng]# docker pull hello-world\r\nUsing default tag: latest # 如果不写tag,默认就是latest\r\nlatest: Pulling from library/hello-world\r\n93288797bd35: Pull complete  #分层下载，docker image的核心 联合文件系统\r\n93287127bd35: Pull complete\r\nDigest: sha256:37a0b92b08d4919615c3ee023f7ddb012b8387475d64c622ac30f45c29c51\r\nStatus: Downloaded newer image for hello-world:latest\r\ndocker.io/library/hello-world:latest #真实地址\r\n\r\n等价于它\r\ndocker pull hello-world\r\ndocker pull docker.io/library/hello-world:latest\r\n</code></pre>\r\n<h4 id=\"1625\">docker rmi 删除镜像</h4>\r\n<pre class=\"lang-shell\"><code data-language=\"shell\" class=\"hljs language-shell\">[root@192 wfeng]# docker rmi -f ecac195d15af   #指定id删除\r\n[root@192 wfeng]# docker rmi -f id1 id2        #多个删除\r\n[root@192 wfeng]# docker rmi -f $(docker images -aq)    #全部删除\r\n</code></pre>\r\n<hr>\r\n<h3 id=\"1804\">容器命令</h3>\r\n<hr>\r\n<p>说明：有了镜像才可以创建容器</p>\r\n<pre class=\"lang-shell\"><code data-language=\"shell\" class=\"hljs language-shell\">docker pull centos\r\n</code></pre>\r\n<h4 id=\"1977\">新建容器并启动</h4>\r\n<pre class=\"lang-shell\"><code data-language=\"shell\" class=\"hljs language-shell\">docker run [可选参数] image\r\n<span class=\"hljs-meta prompt_\">\r\n#</span><span class=\"language-bash\">参数说明</span>\r\n--name=\"name\"  容器名字，用来区分容器\r\n-d             后台方式运行\r\n-it            使用交互方式运行，进入容器查看内容\r\n-p			   指定容器的端口 -p 8080:8080\r\n	-p ip:主机端口:容器端口\r\n	-p 主机端口:容器端口 （常用）\r\n	-p 容器端口\r\n	容器端口\r\n-p			   随机指定端口\r\n<span class=\"hljs-meta prompt_\">\r\n# </span><span class=\"language-bash\">测试，启动并进入容器</span>\r\n[root@192 wfeng]# docker run -it centos /bin/bash\r\n[root@0ec9062b3f77 /]# \r\n<span class=\"hljs-meta prompt_\"># </span><span class=\"language-bash\">退出</span>\r\n[root@0ec9062b3f77 /]# exit\r\n</code></pre>\r\n<h4 id=\"2482\">列出所有的运行的容器</h4>\r\n<pre class=\"lang-shell\"><code data-language=\"shell\" class=\"hljs language-shell\"><span class=\"hljs-meta prompt_\"># </span><span class=\"language-bash\">docekr ps 命令</span>\r\n<span class=\"hljs-meta prompt_\">		# </span><span class=\"language-bash\">列出当前正在运行的容器</span>\r\n-a  	# 列出当前正在运行的容器+带出历史运行过的容器\r\n-n=?	# 显示最近的创建的容器\r\n-q		# 只显示容器的编号\r\n</code></pre>\r\n<h4 id=\"2675\">退出容器</h4>\r\n<pre class=\"lang-shell\"><code data-language=\"shell\" class=\"hljs language-shell\">exit  # 直接退出容器并停止\r\nctrl + p + q  #不停止退出\r\n</code></pre>\r\n<h4 id=\"2796\">删除容器</h4>\r\n<pre class=\"lang-shell\"><code data-language=\"shell\" class=\"hljs language-shell\">docker rm 容器id # 删除指定容器，不能删除运行中的容器，参数 -f 强制删除\r\ndocker rm -f $(docker ps -aq) # 删除所有容器 \r\ndocker ps -a -q | xargs docker rm # 删除所有容器\r\n</code></pre>\r\n<h4 id=\"2941\">启动和停止容器的操作</h4>\r\n<pre class=\"lang-shell\"><code data-language=\"shell\" class=\"hljs language-shell\">docker start 容器id   #启动\r\ndocker restart 容器id #重启\r\ndocker stop 容器id    #停止\r\ndocker kill 容器id    #强制停止\r\n</code></pre>\r\n<h3 id=\"3110\">常用其他命令</h3>\r\n<hr>\r\n<h4 id=\"3189\">后台启动容器</h4>\r\n<pre class=\"lang-shell\"><code data-language=\"shell\" class=\"hljs language-shell\">[root@192 wfeng]# docker run -d centos\r\n<span class=\"hljs-meta prompt_\"># </span><span class=\"language-bash\">问题docker ps,发现 centos 停止了</span>\r\n<span class=\"hljs-meta prompt_\">\r\n# </span><span class=\"language-bash\">常见的坑：docker 容器使用后台运行，就必须要有一个前台进程，docker发现没有应用，就会自动停止</span>\r\n<span class=\"hljs-meta prompt_\"># </span><span class=\"language-bash\">nginx,容器启动后，发现自己没有提供服务，就会立刻停止，就是没有程序了</span>\r\n</code></pre>\r\n<h4 id=\"3387\">查看日志</h4>\r\n<pre class=\"lang-shell\"><code data-language=\"shell\" class=\"hljs language-shell\">docker logs -tf --tail 10 容器id\r\n-tf 			# 显示日志\r\n--tail number   # 显示日志条数\r\n</code></pre>\r\n<h4 id=\"3532\">查看容器中进程信息ps</h4>\r\n<pre class=\"lang-shell\"><code data-language=\"shell\" class=\"hljs language-shell\">docker top 容器id\r\n</code></pre>\r\n<h4 id=\"3629\">查看容器元数据</h4>\r\n<pre class=\"lang-shell\"><code data-language=\"shell\" class=\"hljs language-shell\">docker inspect 容器id\r\n</code></pre>\r\n<h4 id=\"3726\">进入当前正在运行的容器</h4>\r\n<pre class=\"lang-shell\"><code data-language=\"shell\" class=\"hljs language-shell\"><span class=\"hljs-meta prompt_\"># </span><span class=\"language-bash\">命令</span>\r\ndocker exec -it 容器id bashShell # 进入容器打开一个新的终端\r\ndocker attach 容器id # 进入正在运行的一个终端\r\n</code></pre>\r\n<h4 id=\"3871\">从容器内拷贝文件到主机上</h4>\r\n<pre class=\"lang-shell\"><code data-language=\"shell\" class=\"hljs language-shell\">docker cp 容器id:容器内路径  目的的主机路径\r\n\r\n[root@57721483c31b home]# touch test.java\r\n[root@57721483c31b home]# exit\r\nexit\r\n[root@192 wfeng]# docker ps\r\nCONTAINER ID   IMAGE     COMMAND   CREATED   STATUS    PORTS     NAMES\r\n[root@192 wfeng]# docker cp 57721483c31b:/home/test.java test.java\r\n[root@192 wfeng]# ls\r\ntest.java\r\n</code></pre>\r\n<h4 id=\"4184\">小结</h4>\r\n<p><img src=\"https://img-blog.csdn.net/2018071915491757?watermark/2/text/aHR0cHM6Ly9ibG9nLmNzZG4ubmV0L3FxXzE2MjkwNzkx/font/5a6L5L2T/fontsize/400/fill/I0JBQkFCMA==/dissolve/70\" alt=\"img\"></p>\r\n<h3 id=\"4269\">容器数据卷</h3>\r\n<h4 id=\"4315\">挂载目录</h4>\r\n<p>实现主机与容器文件共享</p>\r\n<pre class=\"lang-shell\"><code data-language=\"shell\" class=\"hljs language-shell\"><span class=\"hljs-meta prompt_\"># </span><span class=\"language-bash\">指定目录</span>\r\ndocker run -v 主机目录:容器目录 镜像\r\n<span class=\"hljs-meta prompt_\">\r\n# </span><span class=\"language-bash\">匿名挂载</span>\r\ndocker run -v /容器目录 镜像\r\n<span class=\"hljs-meta prompt_\">\r\n# </span><span class=\"language-bash\">具名挂载</span>\r\ndocker run -v 卷名:/容器目录 镜像\r\n\r\n[root@192 wfeng]# docker run -d -p 3310:3306 -v /home/edk/mysql/conf:/etc/mysql/conf.d -v /home/edk/mysql/data:/var/lib/mysql -e MYSQL_ROOT_PASSWORD=123456 --name mysql5.7 ibex/debian-mysql-server-5.7\r\n<span class=\"hljs-meta prompt_\">\r\n\r\n#</span><span class=\"language-bash\"><span class=\"hljs-comment\">### 未指定目录的情况下都是在：/var/lib/docker/volume/xxx/_data  大多数使用具名挂载</span></span>\r\n</code></pre>\r\n<p>拓展</p>\r\n<pre class=\"lang-shell\"><code data-language=\"shell\" class=\"hljs language-shell\"><span class=\"hljs-meta prompt_\"># </span><span class=\"language-bash\">ro  <span class=\"hljs-built_in\">readonly</span> 只读，只能通过主机来操作，容器内部无法操作</span>\r\n<span class=\"hljs-meta prompt_\"># </span><span class=\"language-bash\">rw  <span class=\"hljs-built_in\">read</span>/write  可读可写</span>\r\ndocker run -d -P --name nginx02 -v nginx02:/etc/nginx:ro nginx\r\ndocker run -d -P --name nginx02 -v nginx02:/etc/nginx:rw nginx\r\n</code></pre>\r\n<h3 id=\"4912\">数据卷容器</h3>\r\n<p>--volume-from 容器</p>\r\n<h3 id=\"4999\">Dockerfile</h3>\r\n<h4 id=\"5045\">Dockerfile介绍</h4>\r\n<p>dockerfile 是用来构建docker镜像的文件！命令参数脚本！<br>\r\n步骤：</p>\r\n<ul>\r\n<li>编写一个 dockerfile 文件</li>\r\n<li>docker build 构建成为一个镜像</li>\r\n<li>docker run 运行镜像</li>\r\n<li>docker push 发布镜像（DockerHub,阿里仓库）</li>\r\n</ul>\r\n<hr>\r\n<h4 id=\"5297\">Dockerfile构建过程</h4>\r\n<p><em><strong>基础知识</strong></em></p>\r\n<ul>\r\n<li>命令必须是大写字母</li>\r\n<li>执行顺序从上到下</li>\r\n<li>#表示注释</li>\r\n<li>每个指令都会创建提交一个新的镜像层，并提交！</li>\r\n</ul>\r\n<h4 id=\"5489\">Dockerfile 指令</h4>\r\n<pre class=\"lang-shell\"><code data-language=\"shell\" class=\"hljs language-shell\">FROM            # 基础镜像\r\nMAINTAINER      # 创建者\r\nRUN             # 镜像构建的时候需要运行的命令\r\nADD             # 添加镜像内容,tar类型文件会自动解压(网络压缩资源不会被解压)，可以访问网络资源，类似wget\r\nWORKDIR         # 镜像的工作目录,类似于cd命令\r\nVOLUME          # 挂载的目录\r\nEXPOSE          # 对外暴露的端口\r\nCMD             # 指定容器启动的时候运行的命令，只有最后一个会成效，可被替代\r\nENTRYOPOINT     # 指定容器启动的时候运行的命令，可以追加\r\nONBUILD         # 当构建一个被继承 DockerFile 这个时候就会运行 ONBUILD 的指令，触发指令\r\nCOPY            # 类似ADD,将我们的文件拷贝到镜像中,但是是不会自动解压文件，也不能访问网络资源\r\nENV             # 构建的时候设置环境变量\r\n</code></pre>\r\n<h4 id=\"5855\">DockerFile 实战</h4>\r\n<p>Docker Hub 中99%都是从这个基础镜像过来的 FROM scratch,然后配置需要的软件和配置来进行构建</p>\r\n<blockquote>\r\n<p>测试创建一个centos镜像</p>\r\n</blockquote>\r\n<pre class=\"lang-shell\"><code data-language=\"shell\" class=\"hljs language-shell\"><span class=\"hljs-meta prompt_\"># </span><span class=\"language-bash\">1.编写dockerfile文件</span>\r\nFROM centos\r\nMAINTAINER wfeng&lt;1224971566@qq.com&gt;\r\n\r\nENV MYPATH /usr/local\r\nWORKDIR $MYPATH\r\n\r\n\r\nRUN yum -y install vim\r\nRUM yum -y install net-tools\r\n\r\nEXPOSE 80\r\n\r\nCMD echo $MYPATH\r\nCMD echo \"---end---\"\r\nCMD /bin/bash\r\n<span class=\"hljs-meta prompt_\">\r\n# </span><span class=\"language-bash\">2.通过文件构建镜像</span>\r\n<span class=\"hljs-meta prompt_\"># </span><span class=\"language-bash\">命令： docker build -f 文件 -t 镜像名:版本 .</span>\r\n</code></pre>\r\n<h4 id=\"6496\">发布镜像</h4>\r\n<pre class=\"lang-shell\"><code data-language=\"shell\" class=\"hljs language-shell\"><span class=\"hljs-meta prompt_\"># </span><span class=\"language-bash\">1.登录 dockerhub</span>\r\n[root@192 dockerfile]# docker login -u fengziy\r\nPassword:\r\nWARNING! Your password will be stored unencrypted in /root/.docker/config.json.\r\nConfigure a credential helper to remove this warning. See\r\nhttps://docs.docker.com/engine/reference/commandline/login/#credentials-store\r\n\r\nLogin Succeeded\r\n<span class=\"hljs-meta prompt_\">\r\n# </span><span class=\"language-bash\">2.push hub</span>\r\n<span class=\"hljs-meta prompt_\"># </span><span class=\"language-bash\">规范镜像名才能push  docker push 用户名/镜像名[:tag]</span>\r\n[root@192 dockerfile]# docker push fengziy/mycentos:0.1\r\nThe push refers to repository [docker.io/library/mycentos]\r\n591b3cb2ac87: Preparing\r\nc4651d2a50d0: Preparing\r\nd871dadfb37b: Preparing\r\n</code></pre>\r\n<h5 id=\"6953\">发布阿里云镜像仓库</h5>\r\n<ol>\r\n<li>登录阿里云Docker Registry</li>\r\n</ol>\r\n<pre class=\"lang-shell\"><code data-language=\"shell\" class=\"hljs language-shell\">[root@192 wfeng]# docker login --username=182*****507 registry.cn-shenzhen.aliyuncs.com\r\nPassword:\r\nWARNING! Your password will be stored unencrypted in /root/.docker/config.json.\r\nConfigure a credential helper to remove this warning. See\r\nhttps://docs.docker.com/engine/reference/commandline/login/#credentials-store\r\n\r\nLogin Succeeded\r\n</code></pre>\r\n<ol start=\"2\">\r\n<li>pull/push</li>\r\n</ol>\r\n<pre class=\"lang-shell\"><code data-language=\"shell\" class=\"hljs language-shell\">docker pull registry.cn-shenzhen.aliyuncs.com/fengziy/镜像:[镜像版本号]\r\ndocker push registry.cn-shenzhen.aliyuncs.com/fengziy/镜像:[镜像版本号]\r\n</code></pre>\r\n<hr>\r\n<h3 id=\"7372\">Docker网络（容器编排 集群）</h3>\r\n<p>#veth-pair技术 一对虚拟设备接口<br>\r\n容器之间通信通过 docker0 网桥转发</p>\r\n<h4 id=\"7485\">--link 连接容器,通过容器名</h4>\r\n<p>本质：修改了 hosts 映射</p>\r\n<pre class=\"lang-shell\"><code data-language=\"shell\" class=\"hljs language-shell\">docker run -d -P --name tomcat01 tomcat\r\ndocker run -d -P --name tomcat02 --link tomcat01 tomcat\r\ndocker exec -it tomcat02 ping tomcat01\r\n</code></pre>\r\n<h4 id=\"7671\">自定义网络</h4>\r\n<pre class=\"lang-shell\"><code data-language=\"shell\" class=\"hljs language-shell\"><span class=\"hljs-meta prompt_\">#</span><span class=\"language-bash\">网卡列表</span>\r\n[root@192 wfeng]# docker network ls\r\nNETWORK ID     NAME      DRIVER    SCOPE\r\n5b37dfde19ba   bridge    bridge    local\r\n76afc652c9c4   host      host      local\r\n1c29823208de   none      null      local\r\n<span class=\"hljs-meta prompt_\">\r\n#</span><span class=\"language-bash\">网络模式</span>\r\n<span class=\"hljs-meta prompt_\">#</span><span class=\"language-bash\">bridge：桥接 docker 默认</span>\r\n<span class=\"hljs-meta prompt_\">#</span><span class=\"language-bash\">none: 不配置</span>\r\n<span class=\"hljs-meta prompt_\">#</span><span class=\"language-bash\">host：和主机共享</span>\r\n<span class=\"hljs-meta prompt_\">\r\n# </span><span class=\"language-bash\">默认网络参数是：--net bridge</span>\r\n[root@192 wfeng]# docker run -d -P --name tomcat01 --net bridge tomcat\r\n<span class=\"hljs-meta prompt_\">\r\n\r\n#</span><span class=\"language-bash\">创建网络</span>\r\n[root@192 wfeng]# docker network create --driver bridge --subnet 192.168.0.0/16 --gateway 192.168.0.1 mynet\r\n800c94b5ff39de6874ce89dc12a39b3c66dd0aca328138dfd671f348501f5485\r\n[root@192 wfeng]# docker run -d -it --name centos02 --net mynet centos\r\n379a4ff7d36c8e79ad6f83a3aadb1036dfab5f4fc2855af88d52e7e349ed071f\r\n[root@192 wfeng]# docker run -d -it --name centos01 --net mynet centos\r\nc65f745c64509541c193c2f3d2676a6d68438e6e1fd28c801bd1eddf64e2e0d4\r\n<span class=\"hljs-meta prompt_\">\r\n#</span><span class=\"language-bash\">测试ping容器名称</span>\r\n[root@192 wfeng]# docker exec -it centos01 ping centos02\r\nPING centos02 (192.168.0.2) 56(84) bytes of data.\r\n64 bytes from centos02.mynet (192.168.0.2): icmp_seq=1 ttl=64 time=0.656 ms\r\n</code></pre>\r\n<h4 id=\"8421\">容器连接一个网络</h4>\r\n<pre class=\"lang-shell\"><code data-language=\"shell\" class=\"hljs language-shell\">docker network connet 网络 容器\r\n</code></pre>'),(8, 8, '<h3 id=\"194\">python案例1-爬取优美桌面壁纸</h3>\r\n<h4 id=\"240\">效果</h4>\r\n<p><img src=\"https://z3.ax1x.com/2021/06/08/2BHOGq.md.png\" alt=\"2BHOGq.md.png\"><br>\r\n<img src=\"https://z3.ax1x.com/2021/06/08/2BHjzV.md.png\" alt=\"2BHjzV.md.png\"></p>\r\n<h4 id=\"351\">代码</h4>\r\n<pre class=\"lang-python\"><code data-language=\"python\" class=\"hljs language-python\"><span class=\"hljs-keyword\">import</span> os\r\n<span class=\"hljs-keyword\">import</span> requests\r\n\r\n\r\n<span class=\"hljs-comment\"># 壁纸</span>\r\n<span class=\"hljs-keyword\">class</span> <span class=\"hljs-title class_\">Biz</span>(<span class=\"hljs-title class_ inherited__\">object</span>):\r\n    <span class=\"hljs-keyword\">def</span> <span class=\"hljs-title function_\">__init__</span>(<span class=\"hljs-params\">self</span>):\r\n        self.save_folder = <span class=\"hljs-string\">\"E:/wallpic2/\"</span>\r\n        self.totalPages = <span class=\"hljs-number\">0</span>\r\n        self.page = <span class=\"hljs-number\">0</span>\r\n        self.url = <span class=\"hljs-string\">\"https://infinity-api.infinitynewtab.com/get-wallpaper?page=%d\"</span>\r\n\r\n    <span class=\"hljs-keyword\">def</span> <span class=\"hljs-title function_\">get_json</span>(<span class=\"hljs-params\">self</span>):\r\n        json = requests.get(self.url % self.page).json()\r\n        self.totalPages = json[<span class=\"hljs-string\">\"totalPages\"</span>]\r\n        <span class=\"hljs-built_in\">print</span>(<span class=\"hljs-string\">\"拉取第 %d 页, %d 条数据\"</span> % (self.page, <span class=\"hljs-built_in\">len</span>(json[<span class=\"hljs-string\">\"data\"</span>])))\r\n        <span class=\"hljs-keyword\">return</span> json[<span class=\"hljs-string\">\"data\"</span>]\r\n\r\n    <span class=\"hljs-keyword\">def</span> <span class=\"hljs-title function_\">download_img</span>(<span class=\"hljs-params\">self, file_path, url</span>):\r\n        file_path = os.path.join(self.save_folder, <span class=\"hljs-built_in\">str</span>(self.page), file_path)\r\n        rep = requests.get(url).content\r\n        <span class=\"hljs-keyword\">with</span> <span class=\"hljs-built_in\">open</span>(file_path, <span class=\"hljs-string\">\"wb\"</span>) <span class=\"hljs-keyword\">as</span> f:\r\n            f.write(rep)\r\n            <span class=\"hljs-built_in\">print</span>(<span class=\"hljs-string\">\"下载完成,保存到：\"</span>+file_path)\r\n\r\n    <span class=\"hljs-keyword\">def</span> <span class=\"hljs-title function_\">save_url</span>(<span class=\"hljs-params\">self, file_mane, url</span>):\r\n        <span class=\"hljs-keyword\">with</span> <span class=\"hljs-built_in\">open</span>(os.path.join(self.save_folder,file_mane), <span class=\"hljs-string\">\"a\"</span>, encoding=<span class=\"hljs-string\">\"utf-8\"</span>) <span class=\"hljs-keyword\">as</span> f:\r\n            f.write(url + <span class=\"hljs-string\">\'\\n\'</span>)\r\n\r\n    <span class=\"hljs-keyword\">def</span> <span class=\"hljs-title function_\">run</span>(<span class=\"hljs-params\">self</span>):\r\n        <span class=\"hljs-keyword\">while</span> self.page &lt;= self.totalPages:\r\n            index = <span class=\"hljs-number\">1</span>\r\n            data = self.get_json()\r\n            self.make_folder(os.path.join(self.save_folder, <span class=\"hljs-built_in\">str</span>(self.page)))\r\n            <span class=\"hljs-keyword\">for</span> i <span class=\"hljs-keyword\">in</span> data:\r\n                url = i[<span class=\"hljs-string\">\"src\"</span>][<span class=\"hljs-string\">\"rawSrc\"</span>]\r\n                file_path = i[<span class=\"hljs-string\">\"_id\"</span>]+<span class=\"hljs-string\">\".\"</span>+url.split(<span class=\"hljs-string\">\".\"</span>)[-<span class=\"hljs-number\">1</span>]\r\n                <span class=\"hljs-comment\"># 保存地址</span>\r\n                self.save_url(<span class=\"hljs-string\">\"url.txt\"</span>, url)\r\n                <span class=\"hljs-comment\"># 下载图片</span>\r\n                self.download_img(file_path, url)\r\n                <span class=\"hljs-built_in\">print</span>(<span class=\"hljs-string\">\"开始下载第 %s 页,第 %d 图：%s\"</span> % (self.page, index, url))\r\n                index += <span class=\"hljs-number\">1</span>\r\n            self.page += <span class=\"hljs-number\">1</span>\r\n\r\n    <span class=\"hljs-keyword\">def</span> <span class=\"hljs-title function_\">make_folder</span>(<span class=\"hljs-params\">self, path=<span class=\"hljs-literal\">None</span></span>):\r\n        <span class=\"hljs-keyword\">if</span> path <span class=\"hljs-keyword\">is</span> <span class=\"hljs-literal\">None</span>:\r\n            path = self.save_folder\r\n        <span class=\"hljs-keyword\">if</span> <span class=\"hljs-keyword\">not</span> os.path.exists(path):\r\n            os.makedirs(path)\r\n\r\n\r\n<span class=\"hljs-keyword\">if</span> __name__ == <span class=\"hljs-string\">\'__main__\'</span>:\r\n    biz = Biz()\r\n    biz.run()\r\n</code></pre>\r\n<blockquote>\r\n<p>优化：可以用上多线程提高爬虫效率，在此就不展开了，有兴趣的小伙伴可以去看看。</p>\r\n</blockquote>'),(9, 9, '<h3 id=\"194\">python案例1-爬取优美桌面壁纸</h3>\r\n<h4 id=\"240\">效果</h4>\r\n<p><img src=\"https://z3.ax1x.com/2021/06/08/2BHOGq.md.png\" alt=\"2BHOGq.md.png\"><br>\r\n<img src=\"https://z3.ax1x.com/2021/06/08/2BHjzV.md.png\" alt=\"2BHjzV.md.png\"></p>\r\n<h4 id=\"351\">代码</h4>\r\n<pre class=\"lang-python\"><code data-language=\"python\" class=\"hljs language-python\"><span class=\"hljs-keyword\">import</span> os\r\n<span class=\"hljs-keyword\">import</span> requests\r\n\r\n\r\n<span class=\"hljs-comment\"># 壁纸</span>\r\n<span class=\"hljs-keyword\">class</span> <span class=\"hljs-title class_\">Biz</span>(<span class=\"hljs-title class_ inherited__\">object</span>):\r\n    <span class=\"hljs-keyword\">def</span> <span class=\"hljs-title function_\">__init__</span>(<span class=\"hljs-params\">self</span>):\r\n        self.save_folder = <span class=\"hljs-string\">\"E:/wallpic2/\"</span>\r\n        self.totalPages = <span class=\"hljs-number\">0</span>\r\n        self.page = <span class=\"hljs-number\">0</span>\r\n        self.url = <span class=\"hljs-string\">\"https://infinity-api.infinitynewtab.com/get-wallpaper?page=%d\"</span>\r\n\r\n    <span class=\"hljs-keyword\">def</span> <span class=\"hljs-title function_\">get_json</span>(<span class=\"hljs-params\">self</span>):\r\n        json = requests.get(self.url % self.page).json()\r\n        self.totalPages = json[<span class=\"hljs-string\">\"totalPages\"</span>]\r\n        <span class=\"hljs-built_in\">print</span>(<span class=\"hljs-string\">\"拉取第 %d 页, %d 条数据\"</span> % (self.page, <span class=\"hljs-built_in\">len</span>(json[<span class=\"hljs-string\">\"data\"</span>])))\r\n        <span class=\"hljs-keyword\">return</span> json[<span class=\"hljs-string\">\"data\"</span>]\r\n\r\n    <span class=\"hljs-keyword\">def</span> <span class=\"hljs-title function_\">download_img</span>(<span class=\"hljs-params\">self, file_path, url</span>):\r\n        file_path = os.path.join(self.save_folder, <span class=\"hljs-built_in\">str</span>(self.page), file_path)\r\n        rep = requests.get(url).content\r\n        <span class=\"hljs-keyword\">with</span> <span class=\"hljs-built_in\">open</span>(file_path, <span class=\"hljs-string\">\"wb\"</span>) <span class=\"hljs-keyword\">as</span> f:\r\n            f.write(rep)\r\n            <span class=\"hljs-built_in\">print</span>(<span class=\"hljs-string\">\"下载完成,保存到：\"</span>+file_path)\r\n\r\n    <span class=\"hljs-keyword\">def</span> <span class=\"hljs-title function_\">save_url</span>(<span class=\"hljs-params\">self, file_mane, url</span>):\r\n        <span class=\"hljs-keyword\">with</span> <span class=\"hljs-built_in\">open</span>(os.path.join(self.save_folder,file_mane), <span class=\"hljs-string\">\"a\"</span>, encoding=<span class=\"hljs-string\">\"utf-8\"</span>) <span class=\"hljs-keyword\">as</span> f:\r\n            f.write(url + <span class=\"hljs-string\">\'\\n\'</span>)\r\n\r\n    <span class=\"hljs-keyword\">def</span> <span class=\"hljs-title function_\">run</span>(<span class=\"hljs-params\">self</span>):\r\n        <span class=\"hljs-keyword\">while</span> self.page &lt;= self.totalPages:\r\n            index = <span class=\"hljs-number\">1</span>\r\n            data = self.get_json()\r\n            self.make_folder(os.path.join(self.save_folder, <span class=\"hljs-built_in\">str</span>(self.page)))\r\n            <span class=\"hljs-keyword\">for</span> i <span class=\"hljs-keyword\">in</span> data:\r\n                url = i[<span class=\"hljs-string\">\"src\"</span>][<span class=\"hljs-string\">\"rawSrc\"</span>]\r\n                file_path = i[<span class=\"hljs-string\">\"_id\"</span>]+<span class=\"hljs-string\">\".\"</span>+url.split(<span class=\"hljs-string\">\".\"</span>)[-<span class=\"hljs-number\">1</span>]\r\n                <span class=\"hljs-comment\"># 保存地址</span>\r\n                self.save_url(<span class=\"hljs-string\">\"url.txt\"</span>, url)\r\n                <span class=\"hljs-comment\"># 下载图片</span>\r\n                self.download_img(file_path, url)\r\n                <span class=\"hljs-built_in\">print</span>(<span class=\"hljs-string\">\"开始下载第 %s 页,第 %d 图：%s\"</span> % (self.page, index, url))\r\n                index += <span class=\"hljs-number\">1</span>\r\n            self.page += <span class=\"hljs-number\">1</span>\r\n\r\n    <span class=\"hljs-keyword\">def</span> <span class=\"hljs-title function_\">make_folder</span>(<span class=\"hljs-params\">self, path=<span class=\"hljs-literal\">None</span></span>):\r\n        <span class=\"hljs-keyword\">if</span> path <span class=\"hljs-keyword\">is</span> <span class=\"hljs-literal\">None</span>:\r\n            path = self.save_folder\r\n        <span class=\"hljs-keyword\">if</span> <span class=\"hljs-keyword\">not</span> os.path.exists(path):\r\n            os.makedirs(path)\r\n\r\n\r\n<span class=\"hljs-keyword\">if</span> __name__ == <span class=\"hljs-string\">\'__main__\'</span>:\r\n    biz = Biz()\r\n    biz.run()\r\n</code></pre>\r\n<blockquote>\r\n<p>优化：可以用上多线程提高爬虫效率，在此就不展开了，有兴趣的小伙伴可以去看看。</p>\r\n</blockquote>'),(10, 10, '<p>@<a href=\"%E3%80%90%E9%9D%A2%E8%AF%95%E5%87%86%E5%A4%87%E3%80%911%E3%80%81MySQL%E7%B4%A2%E5%BC%95%E7%AF%87\">TOC</a></p>\r\n<h1 id=\"235\">引言：</h1>\r\n<p>疫情结束自己准备也要面试找工作了，于是浏览了不少招聘的职位简介，和自己所掌握的职业技能一对比后，心里暗叫：不妙呀！很多技术自己还是半灌水啊，被面试官一问不就是露馅了吗。不如趁这个时期在家好好把遗忘的复习复习，不会的好好去研究研究。<br>\r\n博客也荒废了快半年，顺便督促自己好好记录下学习的过程和成果。<br>\r\n<strong>hold！hold！心里戏也是十足，还是回归正题了，毕竟MySQL性能调优中索引相关的问题在面试中是个常问的问题。</strong></p>\r\n<h1 id=\"458\">什么是索引？</h1>\r\n<p>MySQL官方对索引的定义为：==<strong>索引(Index)是帮助MySQL高效获取数据的数据结构。</strong>== 我们可以简单理解为：<strong>索引本质是一种数据结构，其作用是帮助MySQL快速检索。</strong></p>\r\n<h1 id=\"577\">MySQL索引的结构有那些？并简单的介绍。</h1>\r\n<ul>\r\n<li><strong>B+tree索引</strong>（MySQL默认使用该结构）<br>\r\n<img src=\"https://img-blog.csdnimg.cn/2020032015323825.png#pic_center\" alt=\"b+tree\"></li>\r\n</ul>\r\n<blockquote>\r\n<p><strong>特点：</strong></p>\r\n<ul>\r\n<li>由Btree演变，索引在非叶子节点和叶子节点中会有冗余，非叶子节点只存储索引（这也是一个节点可以存储更多索引的原因，查找次数更少），叶子节点存储索引和数据</li>\r\n<li>也遵循二叉树的排序规则，左节点索引小于父节点索引，右节点大于父节点</li>\r\n<li>节点从左到右呈升序排序</li>\r\n<li>叶子节点之间有指针连接，提高区间访问性能（这也是b+tree支持范围查询和排序原因之一）</li>\r\n</ul>\r\n</blockquote>\r\n<ul>\r\n<li><strong>hash索引</strong><br>\r\n<img src=\"https://img-blog.csdnimg.cn/20200320161404928.png#pic_center\" alt=\"hash\"></li>\r\n</ul>\r\n<blockquote>\r\n<p><strong>特点：</strong><br>\r\n查询快速，时间复杂度为O（1）<br>\r\n不支持范围查询和排序</p>\r\n</blockquote>\r\n<h1 id=\"1079\">B+tree在innodb与myisam存储引擎中有何区别?</h1>\r\n<table>\r\n<thead>\r\n<tr>\r\n<th></th>\r\n<th>innodb</th>\r\n<th>myisam</th>\r\n</tr>\r\n</thead>\r\n<tbody>\r\n<tr>\r\n<td>文件格式</td>\r\n<td>索引和数据存储在<strong>ibd文件</strong></td>\r\n<td>索引存储在<strong>myi文件</strong></td>\r\n</tr>\r\n<tr>\r\n<td>索引结构</td>\r\n<td>ID为主键时：叶子节点上数据位存储是行数据，非ID为主键时：数据位储存的是行数据主键</td>\r\n<td>叶子节点上数据位上储存是数据的地址</td>\r\n</tr>\r\n<tr>\r\n<td>事务</td>\r\n<td>支持事务</td>\r\n<td>不支持事务</td>\r\n</tr>\r\n<tr>\r\n<td>锁</td>\r\n<td>行级锁定、表级锁定</td>\r\n<td>表级锁定</td>\r\n</tr>\r\n<tr>\r\n<td>外键</td>\r\n<td>支持</td>\r\n<td>不支持</td>\r\n</tr>\r\n<tr>\r\n<td>可移植性、备份及恢复</td>\r\n<td>灾难恢复性好</td>\r\n<td>并发性差;主机宕机后，MyISAM表易损坏，灾难恢复性不佳</td>\r\n</tr>\r\n</tbody>\r\n</table>\r\n<h3 id=\"1418\">为什么b+tree在innodb为存储引擎时，索引为非ID主键时数据位存储的是行数据主键而不是行数据？</h3>\r\n<p><em>存储引擎是基于表的不是基于数据库的</em><br>\r\n<strong>保持数据的一致性，减少冗余和存储空间。</strong></p>\r\n<h3 id=\"1561\">为什么innodb表必须有主键，并且推荐使用<em>整型</em>的<em>自增</em>主键？</h3>\r\n<ul>\r\n<li>当用于没有声明主键时，MySQL会默认自动在表中增加隐藏字段用于主键储存</li>\r\n<li>整型较于其他数据类型所占空间更少，单节点能储存更多索引</li>\r\n<li>自增主键时，在插入数据时会依次插入到B+tree叶子节点后面；反之插入时会破坏之前的节点，有一个b+tree平衡的过程，降低了插入数据的性能</li>\r\n</ul>\r\n<h1 id=\"1706\">哪些需要创建索引？</h1>\r\n<p>索引虽然能非常高效的提高查询速度，同时却会降低更新表的速度。实际上索引也是一张表，该表保存了主键与索引字段，并指向实体表的记录，所以索引列也是要占用空间的。</p>\r\n<blockquote>\r\n<p>下面图片感觉归纳的不错，从别人<a href=\"https://www.cnblogs.com/qixidi/p/10260180.html\">引用</a>过来的</p>\r\n</blockquote>\r\n<p><img src=\"https://img-blog.csdnimg.cn/20200320220015359.png?x-oss-process=image/watermark,type_ZmFuZ3poZW5naGVpdGk,shadow_10,text_aHR0cHM6Ly9ibG9nLmNzZG4ubmV0L2ZlbmdfemlfeWU=,size_16,color_FFFFFF,t_70\" alt=\"\"></p>\r\n<blockquote>\r\n<p><em>个人浅见欢迎大拿指导</em><br>\r\n<em>向上的路并不拥挤，而大多数人选择了安逸——@fengziy</em></p>\r\n</blockquote>'),(11, 11, 'testcontent');
UNLOCK TABLES;
COMMIT;
BEGIN;
LOCK TABLES `bolg`.`bolg_article_label` WRITE;
DELETE FROM `bolg`.`bolg_article_label`;
INSERT INTO `bolg`.`bolg_article_label` (`id`,`article_id`,`label_id`) VALUES (1, 1, 3),(2, 1, 5),(3, 2, 5),(4, 3, 5),(5, 4, 5),(6, 5, 5),(7, 6, 5),(8, 7, 5),(9, 8, 5),(10, 9, 5),(11, 10, 5);
UNLOCK TABLES;
COMMIT;
BEGIN;
LOCK TABLES `bolg`.`bolg_config` WRITE;
DELETE FROM `bolg`.`bolg_config`;
INSERT INTO `bolg`.`bolg_config` (`id`,`name`,`value`,`type`) VALUES (1, 'title', '落霞与孤鹜齐飞，秋水共长天一色', 1),(2, 'backgroud_img', '/', 1),(3, 'avtator', '/', 1),(4, 'name', 'ORZ_BOLG', 1);
UNLOCK TABLES;
COMMIT;
BEGIN;
LOCK TABLES `bolg`.`bolg_diary` WRITE;
DELETE FROM `bolg`.`bolg_diary`;
UNLOCK TABLES;
COMMIT;
BEGIN;
LOCK TABLES `bolg`.`bolg_diary_content` WRITE;
DELETE FROM `bolg`.`bolg_diary_content`;
UNLOCK TABLES;
COMMIT;
BEGIN;
LOCK TABLES `bolg`.`bolg_diary_label` WRITE;
DELETE FROM `bolg`.`bolg_diary_label`;
UNLOCK TABLES;
COMMIT;
BEGIN;
LOCK TABLES `bolg`.`bolg_friend` WRITE;
DELETE FROM `bolg`.`bolg_friend`;
UNLOCK TABLES;
COMMIT;
BEGIN;
LOCK TABLES `bolg`.`bolg_friend_group` WRITE;
DELETE FROM `bolg`.`bolg_friend_group`;
UNLOCK TABLES;
COMMIT;
BEGIN;
LOCK TABLES `bolg`.`bolg_friend_message` WRITE;
DELETE FROM `bolg`.`bolg_friend_message`;
UNLOCK TABLES;
COMMIT;
BEGIN;
LOCK TABLES `bolg`.`bolg_group` WRITE;
DELETE FROM `bolg`.`bolg_group`;
UNLOCK TABLES;
COMMIT;
BEGIN;
LOCK TABLES `bolg`.`bolg_group_message` WRITE;
DELETE FROM `bolg`.`bolg_group_message`;
UNLOCK TABLES;
COMMIT;
BEGIN;
LOCK TABLES `bolg`.`bolg_group_user` WRITE;
DELETE FROM `bolg`.`bolg_group_user`;
UNLOCK TABLES;
COMMIT;
BEGIN;
LOCK TABLES `bolg`.`bolg_label` WRITE;
DELETE FROM `bolg`.`bolg_label`;
INSERT INTO `bolg`.`bolg_label` (`id`,`label_name`,`create_time`) VALUES (1, 'PHP', '2024-03-26 11:12:55'),(2, 'MySql', '2024-03-26 11:13:12'),(3, 'Docker', '2024-03-26 11:13:20'),(4, '面试', '2024-03-26 11:13:55'),(5, '其他', '2024-03-26 11:14:28');
UNLOCK TABLES;
COMMIT;
BEGIN;
LOCK TABLES `bolg`.`bolg_user` WRITE;
DELETE FROM `bolg`.`bolg_user`;
INSERT INTO `bolg`.`bolg_user` (`user_id`,`user_name`,`account`,`password`,`gender`,`avatar`,`ip`,`login_time`,`create_time`,`update_time`,`status`) VALUES (10000001, 'user_1', '123456', '8b89428b2771f902c61e98ee7a2eb557', 0, '', '', '2023-11-03 10:45:08', '2023-11-02 09:09:19', '2023-11-02 09:09:24', 0),(10000002, 'user_2', '666666', '8b89428b2771f902c61e98ee7a2eb557', 0, '', '', '2023-11-03 10:45:08', '2023-11-03 10:45:02', '2023-11-03 10:45:05', 0),(10000003, 'user_2', '999999', '8b89428b2771f902c61e98ee7a2eb557', 0, '', '', '2023-11-03 10:45:08', '2023-11-03 10:45:08', '2023-11-03 10:45:11', 0);
UNLOCK TABLES;
COMMIT;
